<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <meta http-equiv="X-UA-Compatible" content="ie=edge">
  <title>Document</title>
</head>
<body>
  <div id="root">
    <div class="c1">
      <div title="tt1" id="id">{{ name }}</div>
      <div title="tt2">{{ age }}</div>
      <div title="tt3">{{ gender }}</div>
      <ul>
        <li>1</li>
        <li>2</li>
        <li>3</li>
      </ul>
    </div>
  </div>
  <script src="./watcher.js"></script>
  <script src="./Dep.js"></script>
  <script src="./vnode.js"></script>
  <script src="./compiler.js"></script>
  <script src="./jgvue.js"></script>
  <script src="./initrender.js"></script>
  <script src="./initdata.js"></script>
  <script>
    // rollup
    let app = new JGVue( {
      el: '#root',
      data: {
        name: '张三',
        age: 40,
        gender: '男',
        children: [ 
          { name: '张小一', age: 9, gender: '男' },
          { name: '张小二', age: 6, gender: '女' },
          { name: '张小三', age: 3, gender: '男' },
        ],
        a : {
          b: {
            c: 'jim'
          }
        }
      },

      computed:{
        // 计算属性也是响应式的 ( watcher )
      },

      watch: {
        // 监听什么属性, 这个属性是支持路径语法
        // 也是使用 watcher 实现
        // 'a.b.c': ( oldV, newV ) {  }
      }

    } );
  
  </script>
</body>
</html>